
//手机号屏蔽

public class Test1 {
    public static void main(String[] args) {
        //获取手机号
        String phoneNumber = "12345678910";

        //前段截取
        //左闭右开截取
        String start = phoneNumber.substring(0,3);

        //后段截取
        //给初始，直接截取到末尾
        String end = phoneNumber.substring(7);

        //得到加密手机号
        String result = start + "****" + end;

        System.out.println(result);
    }
}